package icu.sehnen.user.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import icu.sehnen.common.result.CommonResult;
import icu.sehnen.user.entity.Permission;
import icu.sehnen.user.entity.User;

import java.util.List;

/**
 * <p>
 * 后台用户表 服务类
 * </p>
 *
 * @author icu.sehnen
 * @since 2021-04-27
 */
public interface IUserService extends IService<User> {
    User getUserByName(String name);
    List<Permission> getPermissionsByUserId(Long id);
     String login(User user);
    Integer  register(User user);
    IPage<User> getUsers(Long  pageNum, Long  pageSize,User user,String searchTime);
    Integer switchStatus(Long  id,Integer status);
    User findUserById(Long id);
    Integer deleteUserById(Long id);
   List<Permission> getMenusByUserId(Long id);
    CommonResult checkAccessToUri(String uri, String username);
    Integer editUser(User user);
    void addUser(User user);
}
